﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Pages/MaterPage.Master" EnableSessionState="True" AutoEventWireup="true" CodeBehind="UserManagement.aspx.cs" Inherits="AlltrustDinner.Pages.Admin.UserManagement" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script type="text/javascript" src="../../Scripts/Admin/UserManagement.js"></script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">

    <div style="text-align: left">
        <span>用户列表</span>
    </div>
    <div style="text-align: left; vertical-align: middle;">
        ID:<input id="ipt_user_id" type="text" runat="server" />姓名:<input id="ipt_user_name" type="text" runat="server" />
        <asp:ImageButton runat="server" ID="imgBtn_search" ImageUrl="~/Images/search.png" OnClick="imgBtn_search_Click" AlternateText="查询" ImageAlign="AbsMiddle" />
    </div>
    <asp:Repeater ID="rpt_user_list" runat="server">
        <HeaderTemplate>
            <table id="tbl_user_list" class="grdView">
                <thead>
                    <tr>
                        <th style="width: 120px;">ID</th>
                        <th style="width: 240px;">姓名</th>
                        <th style="width: 190px;">余额</th>
                        <th style="width: 120px;">权限</th>
                        <th style="width: 80px;"></th>
                    </tr>
                </thead>
                <tbody>
        </HeaderTemplate>
        <ItemTemplate>
            <tr>
                <td><span alltrusttag="user_info" name="lbl_id"><%# Eval("ID") %></span></td>
                <td><span alltrusttag="user_info" name="lbl_name"><%# Eval("NAME") %></span></td>
                <td><span name="lbl_balance" style="float: left;"><%# Eval("BALANCE","{0:N2}") %></span>
                    <div class="editShow" style="float: left; display: none;">+<input alltrusttag="user_info" type="text" name="ipt_balance_change" style="width: 40px; height: 12px;" /></div>
                </td>
                <td><span name="lbl_right" class="editHide"><%# (Eval("RIGHT").ToString() == "1" ? "管理员" : "普通") %></span>
                    <select alltrusttag="user_info" name="ddl_right" class="editShow" style="display: none; width: 90%;">
                        <option value="0">普通</option>
                        <option value="1">管理员</option>
                    </select>
                    <input name="ipt_right" type="hidden" value="<%# Eval("RIGHT")%>" /></td>
                <td>
                    <img class="editHide" src="../../Images/edit.png" style="float: left; margin-left: 2px; margin-right: 3px; width: 20px; height: 20px;" title="编辑" alt="" onclick="editUser(this);" />
                    <img class="editHide" src="../../Images/delete.png" style="float: left; margin-left: 2px; margin-right: 3px; width: 20px; height: 20px;" title="删除" alt="" onclick="deleteUser(this);" />
                    <img class="editShow" src="../../Images/commit.png" style="display: none; float: left; margin-left: 2px; margin-right: 3px; width: 20px; height: 20px;" title="提交" alt="" onclick="updateUser(this);" />
                    <img class="editShow" src="../../Images/cancel.png" style="display: none; float: left; margin-left: 2px; margin-right: 3px; width: 20px; height: 20px;" title="取消" alt="" onclick="cancelEditUser(this);" />
                </td>
            </tr>

        </ItemTemplate>
        <FooterTemplate>
            </tbody>
            </table>
        </FooterTemplate>
    </asp:Repeater>

</asp:Content>
